package com.yuhong.reggie.mapper;

import com.yuhong.reggie.entity.DishFlavor;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface DishFlavorMapper {
    //插入多条口味数据
    Integer save(@Param("dishFlavorList") List<DishFlavor> dishFlavorList);

    //根据菜品id获取口味列表
    @Select("select *from dish_flavor where dish_id=#{dishId} and is_deleted=0")
    List<DishFlavor> findByDishId(Long dishId);
}
